<?php

namespace Sifast\ProjectBundle\Admin;

use Sonata\AdminBundle\Admin\Admin;
use Sonata\AdminBundle\Datagrid\ListMapper;
use Sonata\AdminBundle\Datagrid\DatagridMapper;
use Sonata\AdminBundle\Form\FormMapper;

class PrimesTransportAdmin extends Admin
{
 
    protected function configureFormFields(FormMapper $formMapper)
    {
        $formMapper
        ->with('L1')
            ->add('cPrimeTransport')
            ->add('cTransportRp')
                ->end()
                ->with('L2')
            ->add('mtPrTransportRp')
            ->add('pourcentageTaxeTransport')
                ->end();
    }

    protected function configureDatagridFilters(DatagridMapper $datagridMapper)
    {
        $datagridMapper
            ->add('cPrimeTransport')
            ->add('cTransportRp')
            ->add('mtPrTransportRp')
            ->add('pourcentageTaxeTransport');
            
    }

    protected function configureListFields(ListMapper $listMapper)
    {
        $listMapper
            ->addIdentifier('cPrimeTransport')
            ->add('cTransportRp')
            ->add('mtPrTransportRp')
            ->add('pourcentageTaxeTransport');
            
            }
}